<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta
      name="viewport"
      content="width=device-width,initial-scale=1.0,maixmum-scale=1.0,minimum-scale=1.0,user-scalable=no"
    />
    <meta http-equiv="X-UA-Compatible" content="ie=edge" />
    <title>Document</title>
    <link rel="stylesheet" href="css/base.css" />
    <link rel="stylesheet" href="css/public.css" />
    <link rel="stylesheet" href="css/sweetalert.css">
    <link rel="stylesheet" href="css/style.css" />
  </head>
  <body>
    <div class="header_login flex">
      <div class="left"><img src="images/goback.png" alt="" /></div>
      <div class="center">找回密码</div>
      <div class="right">登录</div>
    </div>
    <div class="registerbox">
        <div class="sendtext">短信动态验证已发送至   <span>2321312313</span> </div>
      <div class="input_box flex">
        <div class="input">
          <input type="text" id="phone" placeholder="短信验证码" />
        </div>
      </div>
      <div class="input_box flex">
        <div class="input">
          <input type="text" id="newpassword" placeholder="新密码" />
        </div>
      </div>
      
       
        <button class="login_btn btn_gray">提交</button>

    </div>
  </body>
  <script src="js/jquery-1.12.0.min.js"></script>
  <script src="js/public.js"></script>
  <script src="js/sweetalert.min.js"></script>
  <script>
      $("#phone").bind("input propertychange",function(event){
       console.log($("#phone").val())
       if($("#phone").val()){
        $(".login_btn").removeClass("btn_gray")
       }
});
$(".login_btn").click(function(){
    if($("#phone").val()&&$("#newpassword").val()){
        swal("OMG!", "数据为必填", "error");
       }
})
  
  </script>
</html>
